* {
  margin: 0;
  padding: 0;
}

body {
  width: 100w;
  height: 100vh;
}

.carousel {
  position: relative;
  width: 800px;
  height: 500px;
  border: 1px solid #000;
  margin: 100px auto;
  overflow: hidden;
}
.pic {
  position: absolute;
  width: 5000%;
  height: 500px;
  left: 0;
  top: 0;
  transition: all 2s ease;
}
.pic img {
  float: left;
}
/* 通过不同的表单被选中的状态，控制后面 pic 的样式 */
.carousel .check1:checked ~ .pic {
  left: 0;
}
.carousel .check2:checked ~ .pic {
  left: -800px;
}
.carousel .check3:checked ~ .pic {
  left: -1600px;
}
.carousel .check4:checked ~ .pic {
  left: -2400px;
}
.btn {
  position: absolute;
  left: 100px;
  bottom: 50px;
}
.btn label {
  float: left;
  width: 20px;
  height: 20px;
  margin-right: 20px;
  background-color: #fff;
  cursor: pointer;
}
